package com.earthchen.hbase.hos.core.exception;

/**
 * 全局抽象统一异常
 *
 * @author: EarthChen
 * @date: 2018/07/31
 */
public abstract class AbstractHosException extends RuntimeException {

    private static final long serialVersionUID = 6407902098683470561L;

    /**
     * 错误消息
     */
    private String errorMessage;

    public AbstractHosException(String message, Throwable cause) {
        super(cause);
        this.errorMessage = message;
    }

    public abstract int errorCode();

    public String getErrorMessage() {
        return this.errorMessage;
    }
}
